package com.ruoyi.consumer.controller.wallet;

import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.consumer.domain.CWalletCompany;
import com.ruoyi.consumer.domain.CWalletPerson;

import javax.servlet.http.HttpServletResponse;
import java.util.Map;

public interface WalletService {

    public int updateSign(Map<String, Object> walletInfo);
    //更新公司签名
    public int updateCompanySign(Map<String, Object> walletInfo);

    public boolean walletSignCheck(Map<String, Object> walletInfo);

    public int saveError(Map<String, Object> walletInfo, CWalletPerson cWalletPersonFirst, CWalletPerson c);

    public int saveErrorCompany(Map<String, Object> walletInfo, CWalletCompany cWalletPersonFirst, CWalletCompany cWalletPersonLater);

    public Map<String, Object> buildWalletInfoMap(CWalletPerson cWalletPerson);

    public Map<String, Object> buildCompanyWalletInfoMap(CWalletCompany cWalletCompany);

    public String encodeHMAC(Map<String, Object> data, String walletCheckKey);

    public AjaxResult rechargePersonWallet(Integer userId, Integer money);

    public AjaxResult expensePersonWallet(Integer userId, Long free);

    public AjaxResult expenseCompanyWallet(Integer userId, Long free);

    public int updatePersonWallet(Integer userId, Long money);

    //    个人加注更新钱包
    public int updateFillPersonWallet(Integer userId, Long money);

    //    公司加注更新钱包
    public int updateFillCompanyWallet(Integer userId, Long money);

    public Long rechargeWallet(String type, Integer money);

    public void responseToWeixin(HttpServletResponse response, String xml);

    public AjaxResult payNotice(String xml);

    public AjaxResult refund(String orderNum, Integer refundFee);

    public AjaxResult rechargeCompanyWallet(Integer PersonId, Long free);

    public int updateCompanyWallet(Integer userId, Long money);

    public int saveCompanError(Map<String, Object> walletInfo, CWalletCompany cWalletPersonFirst, CWalletCompany cWalletPersonLater);
}
